One way of storing data in a computer system is to store files in a directory structure. The directory structure normally includes a variety of information about any files and sub-directories within the directory structure. One piece of information included in the directory for each file or sub-directory is a directory listing that includes a field containing the physical location, or a pointer to a physical location, on a storage device, such as a disk drive or other non-volatile storage medium, where the file or sub-directory is located. Deletion of a file or sub-directory from the directory typically consists of removing only the directory listing. Once the directory listing has been deleted the system can no longer access the file or sub-directory because it does not know the physical location on the storage device for the file or sub-directory. However, the file or sub-directory is usually still stored on the storage device and can be recovered through the use of well known data recovery techniques.
One way to prevent recovery of deleted data is to explicitly zero, or overwrite, all data at the physical location pointed to by the directory listing. However, this can be a cumbersome process. Particularly, if there are large amounts of data stored on the storage device. The problem can be even more difficult in a heap data structure because it is generally not clear when data within the structure is discarded. In a conventional heap, data is only discarded when the data becomes inaccessible via the heap structure, i.e. an access path within the heap structure no longer includes any pointers to the data. Discarding data in this environment typically consists of deleting any pointer that includes the physical location of the data on a storage device. The data itself is generally not deleted. Due to the uncertainty as to when the pointers, which include the physical location of the data, is discarded it can be difficult and cumbersome to overwrite or zero the data at its physical location on the storage device.